<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script type="text/javascript">
        function ch(){
            var result = confirm("Please make sure. ");
            if (result == true) {
                alert("Hello World! ");
            } else {
                alert("Bye!");
            }
        }
    </script>
</head>
<body>
    <input type="button" value="Click Me!" onclick="ch()" />
</body>
</html>